// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import 'element-ui/lib/theme-default/index.css'
import '@ass/icon/style.css'
import '@ass/font/style.css'
import '@ass/css/reset.min.css'
import Vue from 'vue'
import ElementUI from 'element-ui'
import App from './App'
import router from '@pl/router'
import store from '@pl/vuex-store'

Vue.use(ElementUI)

// Vue.config.productionTip = false

router.beforeEach((to, from, next) => {
	if (to.path != '/tasklist') {
		return next('/tasklist')
	}
	return next()
})

/* eslint-disable no-new */
new Vue({
	el: '#app',
	store,
	router,
	template: '<App/>',
	components: {
		App,
	},
	render: h => h(App),
})